Tom Leighton and Eric Lehman Problem Set 5 Solutions
نویسنده
چکیده
(a) Find a closed-form expression for the diameter of the ternary tree. Solution. The diameter is 2 log3 N + 1. (b) Prove that your expression is correct using induction. Hint: Your induction hypothesis should prove an expression for the length of a path from an input to the root node. Solution. We proceed by induction on n. Let P (n) be the proposition that, in a complete tenary tree with N = 3 inputs and outputs:
منابع مشابه
Design and Implementation of Scalable, Fully Distributed Web Crawler for a Web Search Engine
The Web is a context in which traditional Information Retrieval methods are challenged. Given the volume of the Web and its speed of change, the coverage of modern web search engines is relatively small. Search engines attempt to crawl the web exhaustively with crawler for new pages, and to keep track of changes made to pages visited earlier. The centralized design of crawlers introduces limita...
متن کاملTom Leighton and Ankur Moitra Problem Set 10 Solutions
Problem 1. [20 points] You are organizing a neighborhood census and instruct your census takers to knock on doors and note the sex of any child that answers the knock. Assume that there are two children in a household, that children are equally likely to be girls and boys, and that girls and boys are equally likely to open the door. A sample space for this experiment has outcomes that are tripl...
متن کامل